package com.isi.rightone.services;

import java.io.IOException;
import java.io.Reader;

import com.ibatis.common.resources.Resources;
import com.ibatis.sqlmap.client.SqlMapClient;
import com.ibatis.sqlmap.client.SqlMapClientBuilder;

public class IbatisService {

	public static SqlMapClient sqlMap;

	//***** configuration du sqlMap
	static{
		//config xml
		String ressource = "com/isi/rightone/services/sqlMapConfig.xml";
		try {
			Reader reader = Resources.getResourceAsReader(ressource);
			sqlMap = SqlMapClientBuilder.buildSqlMapClient(reader);
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
			
	}

	
}
